plugins {
	id 'java'
	id 'org.springframework.boot' version '3.0.6'
	id 'io.spring.dependency-management' version '1.1.0'
	id 'org.hibernate.orm' version '6.1.7.Final'
	id 'org.graalvm.buildtools.native' version '0.9.20'
}

group = 'org'
version = '0.1.1'
sourceCompatibility = '17'

configurations {
	compileOnly {
		extendsFrom annotationProcessor
	}
}

repositories {
	mavenCentral()
}

ext {
	set('springShellVersion', "3.0.2")
}

dependencies {
	implementation 'org.springframework.boot:spring-boot-starter-web'
	implementation 'org.springframework.shell:spring-shell-starter'
	implementation group: 'org.jline', name: 'jline-terminal-jna', version: '3.23.0'
	compileOnly 'org.projectlombok:lombok'
	annotationProcessor 'org.springframework.boot:spring-boot-configuration-processor'
	annotationProcessor 'org.projectlombok:lombok'
	testImplementation 'org.springframework.boot:spring-boot-starter-test'
}

dependencyManagement {
	imports {
		mavenBom "org.springframework.shell:spring-shell-dependencies:${springShellVersion}"
	}
}

tasks.named('test') {
	useJUnitPlatform()
}

hibernate {
	enhancement {
		lazyInitialization true
		dirtyTracking true
		associationManagement true
	}
}

